Repository navigation
fix(fe): restrict contest pages to contest admin and manager - #3821
saeyeon-05 wants to merge 1 commit into
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configuration
📒 Files selected for processing (2)
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe contest layout fetches contest roles and renders its children only for a matching Admin or Manager role. Otherwise, it renders a component that redirects to ChangesContest access
Priority: ➖ Normal Estimated code review effort: 2 (Simple) | ~10 minutes Change: Bug fix Sequence Diagram(s)sequenceDiagram
participant Layout as Contest layout
participant Roles as contest/role
participant Denied as ContestAccessDenied
participant Router
participant Toast as Error toast
Layout->>Roles: Fetch contest roles
Roles-->>Layout: Return roles or fetch error
Layout->>Denied: Render when no matching Admin or Manager role exists
Denied->>Router: Replace route with /admin/contest
Denied->>Toast: Show access-denied error after 100 ms
Merge Risk: 🔵 Low · up to A revoked manager may still see contest information already loaded in their browser until refresh. New protected requests are blocked, so this is mergeable with owner awareness. Security Architecture ReviewSecurity architecture risk: 🟡 Moderate · up to The change restricts initial page access, but permissions may remain stale after access is revoked. The existing role lookup also has a missing-identity weakness. Server-side checks limit fresh privileged access, so this is an additional page-access control rather than a complete authorization boundary. Retained concerns Security review detailsSecurity Blast Radius
Security Findings and Attack Paths
Trust Boundaries and Controls
Resilience and Maintainability Implications
Hardening Proposals
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
✅ Syncing Preview App Succeeded Application: |
Description
Closes TAS-3093
Test
Summary by CodeRabbit